<script setup>
import MenuItem from "./MenuItem.vue"
// import menuList from "../../utils/routeconfig"
import { useCollapseStore } from "../../stores/collapse";
import { useUserStore } from "../../stores/user";
const userStore = useUserStore()
const collapseStore = useCollapseStore()

</script>
<template>
    <div class="asidemenu">
        <el-menu :collapse="collapseStore.getCollapse" :router="true" active-text-color="#ffd04b"
            background-color="#545c64" class="el-menu-vertical-demo" default-active="首页" text-color="#fff">
            <template v-for="menu in userStore.getUser.permission" :key="menu.lable">
                <MenuItem :item="menu">
                </MenuItem>
            </template>
        </el-menu>
    </div>
</template>